import { queryFlowin } from '@/services/knowFlow';
const knowFlowModel = {
	namespace: 'knowFlow',
	state: {
		flowinData: [],
	},
	effects: {
		*fetchFlowIn(_, { call, put }) {
			const response = yield call(queryFlowin);
			console.log('====>>>', response)
			yield put({
				type: 'saveFlowin',
				paylaod: response
			})
		}
	},
	reducers: {
		saveFlowin(state, action){
			return {...state, flowinData: action.paylaod || []}
		}
	},
};
export default knowFlowModel;
